Repository navigation
feat(risk): add config-driven bucket ladder and merged whole-share sizing - #824
Conversation
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 887aed80e0
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@codex review |
|
Codex Review: Didn't find any major issues. Chef's kiss. Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
🛡️ Codex Security Review · Automatically triggeredSecurity review completed. No security issues were found in this pull request. Reviewed commit: Only the user who started this review can view the report in Codex. ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
AI Code Review (gemini /
|
AI assistance
This PR was drafted with AI coding assistance and audited via local
gpt-6.2-astraread-only review (0P0; all6P1 and4P2 findings fixed with regression tests) pluspytestandruff.What changed
src/quant_platform_kit/risk/bucket_capital_ladder.pyimplementing the offline, config-driven Layer 1 four-slot capital-ladder orchestrator:BELOW_TIER1,TIER1 [$1.5k, $15k),TIER2 [$15k, $50k),TIER3 >= $50k) with hard$50kBucket D floor, defaultA/B/D = 70/30/0(C = 0%read-only), config-driven per-bucket broker routing,bucket_d_single_stock_max_usd, and console Owner decision prompts.MappingorSequence[tuple[str, float]]) before exactDecimalwhole-share flooring, halted-symbol retention (rejecting barestr), passive single-symbol cap breach add-blocking (while permitting explicit trims/exits), incremental-buy-only slippage, and canonicalestimate_ibkr_commission_usdfee modeling.src/quant_platform_kit/risk/__init__.py.tests/test_bucket_capital_ladder.py.How verified
uv run pytest tests/test_bucket_capital_ladder.py tests/test_benchmark_dca_and_regime.py tests/test_twr_capital_ladder.py -q-> all passed.uv run ruff check src/quant_platform_kit/risk/bucket_capital_ladder.py src/quant_platform_kit/risk/__init__.py tests/test_bucket_capital_ladder.py->All checks passed!.Why
Deliver the first config-driven building block for the permanent full-lifecycle Layer 1 architecture so tier progression, bucket weights, and broker routing are controlled by configuration rather than repeated strategy code edits (
live=OFF,paper=OFF, zero broker I/O).Risk